package com.yungu.swift.report.service.impl;

import com.yungu.swift.base.ResponseData;
import com.yungu.swift.base.model.admin.AdminReportParam;
import com.yungu.swift.report.dao.ReportIndexHourDao;
import com.yungu.swift.report.entity.ReportIndexHour;
import com.yungu.swift.report.service.IndexHourService;
import com.yungu.swift.utils.DateUtils;
import com.yungu.swift.utils.MapUtils;
import com.yungu.swift.utils.StringUtils;
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.*;

@Service
public class IndexHourServiceImpl implements IndexHourService {

    @Autowired
    private ReportIndexHourDao indexHourDao;

    @Override
    public ResponseData<List<ReportIndexHour>> queryIndex(AdminReportParam reportParam) {
        return ResponseData.buildSuccessResponse(indexHourDao.query(MapUtils.convertObjToMap(reportParam)));
    }
}
